package com.wf.dto;

import java.util.HashMap;

/**
 * 合同数据传输对象 (Contract Data Transfer Object)
 *
 * 用于存储和传输合同相关信息。
 *
 * @author mpk
 * @since 2024/8/29 14:44:00
 */
public class ContractMap extends HashMap<String, Object>{


    private static final long serialVersionUID = 4687046117427954195L;

    /**
     * 使用 ContractDTO 初始化 ContractMap 的构造函数。
     *
     * @param contractDTO 合同数据传输对象
     */
    public ContractMap(ContractDTO contractDTO) {
        put("${landlordName}", contractDTO.getLandlordName());
        put("${landlordAddress}", contractDTO.getLandlordAddress());
        put("${landlordPhone}", contractDTO.getLandlordPhone());
        put("${tenantName}", contractDTO.getTenantName());
        put("${tenantIdCard}", contractDTO.getTenantIdCard());
        put("${tenantAddress}", contractDTO.getTenantAddress());
        put("${tenantPhone}", contractDTO.getTenantPhone());
        put("${houseLocation}", contractDTO.getHouseLocation());
        put("${houseArea}", contractDTO.getHouseArea());
        put("${houseStructure}", contractDTO.getHouseStructure());
        put("${publicFacilities}", contractDTO.getPublicFacilities());
        put("${energyFacilities}", contractDTO.getEnergyFacilities());
        put("${startDate}", contractDTO.getStartDate());
        put("${endDate}", contractDTO.getEndDate());
        put("${totalLeasePeriod}", contractDTO.getTotalLeasePeriod());
        put("${monthlyRent}", contractDTO.getMonthlyRent());
        put("${paymentCycle}", contractDTO.getPaymentCycle());
    }

}
